<script setup="js">
import { ref } from 'vue'
const count = ref(0)
import { onMounted } from 'vue'
import Spring360 from './spring360.js'
onMounted(() => {
  console.log('ButtonCounter component mounted.')
  const div = document.createElement('div')
  div.innerHTML = 'Hello from ButtonCounter!'
  const th = document.getElementsByClassName('divp')[0]
  th.appendChild(div)
  new Spring360({
    container:th,
    img:'./src/components/78e9ec2e350027254fe2303f27f39da3.jpg'
  })
})
</script>

<template class="button-counter">
  <button @click="count++">You clicked me {{ count }} times.</button>
  <div class="divp">
    <p>This is a ButtonCounter component.</p>
  </div>
</template>